import React, { Component, Children } from 'react'
import PropTypes from 'prop-types'

// console.log(Children)

export default class Mychildren extends Component {
    render() {
        // console.log(this.props)
        const { children } = this.props
        // console.log(Children.only(children))
        return (
            <div>
                Mychildren  -
                {/* {
                    children.map((item, index) => {
                        return <div key={index}>
                            { item }.00
                        </div>
                    })
                } */}

                {
                    Children.map(children, (item, index) => {
                        return <div key={index}>
                            {item}.00
                        </div>
                    })
                }
            </div>
        )
    }
}
